﻿<!--#include file="BlogCommon.asp" -->
<!--#include file="common/function.asp" -->
<!--#include file="common/library.asp" -->
<!--#include file="common/upfile.asp" -->
<!--#include file="common/cache.asp" -->
<!--#include file="common/checkUser.asp" -->
<%
response.expires=-1 
response.expiresabsolute=now()-1 
response.cachecontrol="no-cache"
'-------------- [Alias] -----------------
If request.QueryString("action") = "checkAlias" then
	If ChkPost() Then
   		dim strcname, checkcdb
   		strcname = Checkxss(request.QueryString("cname"))
   		set checkcdb = conn.execute("select * from [blog_Content] where [log_cname]="""&strcname&"""")
       		if checkcdb.bof or checkcdb.eof then
          		response.write "<img src=""images/check_right.gif"">"
       		else
          		response.write "<img src=""images/check_error.gif"">"
       		end if
    	set checkcdb=nothing
	End If
'------------- [mdown] ---------------
elseif request.QueryString("action") = "type1" then
    If ChkPost() Then
		dim mainurl, main, mainstr
        	mainurl = Checkxss(request.QueryString("mainurl"))
        	main = trim(Checkxss(request.QueryString("main")))
        	response.clear()
        	mainstr = ""
    	If Len(memName)>0 Then
        	mainstr = mainstr & "<img src=""images/download.gif"" alt=""下载文件"" style=""margin:0px 2px -4px 0px""/> <a href="""&mainurl&""" target=""_blank"">"&main&"</a>"
    	Else
        	mainstr = mainstr & "<img src=""images/download.gif"" alt=""只允许会员下载"" style=""margin:0px 2px -4px 0px""/> 该文件只允许会员下载! <a href=""login.asp"">登录</a> | <a href=""register.asp"">注册</a>"
    	End If
    	response.write mainstr
	End If
elseif request.QueryString("action") = "type2" then
    If ChkPost() Then
		dim main2, mstr
        	main2 = Checkxss(request.QueryString("main"))
        	response.clear()
        	mstr = ""
    	If Len(memName) > 0 Then
       		mstr=mstr&"<img src=""images/download.gif"" alt=""下载文件"" style=""margin:0px 2px -4px 0px""/> <a href="""&main2&""" target=""_blank"">下载此文件</a>"
    	Else
       		mstr=mstr&"<img src=""images/download.gif"" alt=""只允许会员下载"" style=""margin:0px 2px -4px 0px""/> 该文件只允许会员下载! <a href=""login.asp"">登录</a> | <a href=""register.asp"">注册</a>"
    	End If
    	response.write mstr
	End If
'--------------- [hidden] -----------------
elseif request.QueryString("action") = "Hidden" then
    If Len(memName) > 0 Then
	   response.write "1"
	Else
	   response.Write "0"
	End If
else
response.write "非法操作!"
End If
%>
